package com.aorise.mapper.camera;

import com.aorise.model.camera.AlarmModel;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.dao.DataAccessException;
import org.springframework.stereotype.Component;

import java.util.List;
import java.util.Map;

/**
 * @Author:psl
 * @Desicription: 智能预警mybatis接口类
 * @Date:Created in  2019-05-28.
 * @Modified By:
 */
@Mapper
@Component(value = "alarmMapper")
public interface AlarmMapper {

    /**
     * @Author:psl
     * @Description 根据条件查询智能预警信息
     * @params: map 查询条件Map
     * @Date:2019-05-28
     * @Return: List<AlarmModel> 智能预警集合
     * @Modified By:
     */
    List<AlarmModel> getAlarmList(Map<String, Object> map) throws DataAccessException;

    /**
     * @Author:psl
     * @Description 根据条件查询智能预警信息总数
     * @params: map 查询条件Map
     * @Date:2019-05-28
     * @Return: Integer 智能预警总数
     * @Modified By:
     */
    Integer getCountAlarm(Map<String, Object> map) throws  DataAccessException;

    /**
     * @Author:cat
     * @Description 新增智能预警信息
     * @params: alarmModel 智能预警信息
     * @Date:2019-06-26
     * @Return: Integer 影响行数
     * @Modified By:
     */
    Integer addAlarm(AlarmModel alarmModel) throws  DataAccessException;

    /**
     * @Author:cat
     * @Description 删除智能预警信息
     * @params: map 查询条件Map
     * @Date:2019-06-26
     * @Return: Integer 影响行数
     * @Modified By:
     */
    Integer deleteAlarm(Map<String, Object> map) throws  DataAccessException;
}
